package com.alibaba.mapper;

import com.alibaba.define.domain.CommentDO;
import org.apache.ibatis.annotations.MapKey;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;
import java.util.Map;
import java.util.Set;

/**
 * @author : hanyang
 * @date : 2023-11-04 15:48
 **/

@Mapper
public interface CommentMapper {

    List<CommentDO> select(Map<String, Object> conditionMap);

    Integer insert(CommentDO commentDO);

    Integer count(Map<String, Object> conditionMap);

    /**
     * 子评论查询
     */
    List<CommentDO> selectChildrenCommentByRootIds(@Param("rootIds") Set<Long> rootIds,
                                                   @Param("type") Integer type);


}
